#!/usr/bin/env bash

dockerImage=repository-docker.dftianyi.com/guangshi/tylinks-community:0.0.1
./mvnw clean package -Dmaven.test.skip=true -Dmaven.build.timestamp="$(date "+%Y-%m-%d %H:%M:%S")"
if [ $? -ne 0 ];then
    echo "构建失败!"
else
  cd ./tylinks-standalone || exit
  docker build -t "$dockerImage" .
fi